
# coding: utf-8

# In[5]:


#5.2
def isOdd(i):
    try:
        i = int(i)
    except:
        print("不是整数")
    return i%2!=0


# In[13]:


#5.3
def isNum(i):
    t = type(eval(i))
    return t == type(1) or t == type(1.1) or t == type(1+2j)


# In[18]:


#5.4
def multi(*lists):
    i = 1
    for e in lists:
        i = i*e
    return i


# In[21]:


#5.5
def isPrime(num):
    tmp =num - 1  
    for i  in range(2,tmp):
        if num %i== 0:
            return False
    return True


# In[35]:


#5.6
import datetime
def printDate(year,mouth,day):
    d = datetime.datetime(year,mouth,day)
    print(d.strftime("%Y-%m-%d"))
    print(d.strftime("%Y,%m,%d"))
    print(d.strftime("%Y,%B %d"))
    print(d.strftime("%Y,%b %d"))
    print(d.strftime("%d %B,%Y"))
    print(d.strftime("%A %Y,%b %d"))
    print(d.strftime("%A %d %B,%Y"))
    print(d.strftime("%a %Y,%b %d"))
    print(d.strftime("%a %d %B,%Y"))
    print(d.strftime("%d %b,%Y"))
    print("{0:%Y}年{0:%m}月{0:%d}日".format(d))
    
printDate(1996,1,1)

